package LuoGu.搜索.过河卒;

import java.util.Scanner;

public class Main_DFS_fail {
    static int [] rx = new int []{1,1,-1,-1,2,2,-2,-2};
    static int [] ry = new int []{2,-2,2,-2,1,-1,1,-1};
    static boolean map [][];
    static long ans = 0;
    static int x;
    static int y;
    public static void main(String[] args) {
        Scanner s = new Scanner(System.in);
        x = s.nextInt();
        y = s.nextInt();
        map = new boolean[40][40];
        int my = s.nextInt();
        int mx = s.nextInt();
        map[my][mx] = true;
        for(int i=0;i<8;i++){
            int nx = mx+rx[i];
            int ny = my+ry[i];
            if(nx>=0&&ny>=0&&nx<x&&ny<y) map[ny][nx] = true;
        }
        dfs(0,0);
        System.out.print(ans);
    }

    public static void dfs(int ox,int oy){
        if(ox>x||oy>y);
        else if(ox==x&&oy==y){
            ans++;
        }
        else if(map[oy][ox]==false){
            dfs(ox+1,oy);
            dfs(ox,oy+1);
        }
    }
}
